package com.cn.service;

import com.cn.entity.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.cn.dao.UserMapper;

@Service
public class UserService {
	@Autowired
	private UserMapper userMapper;

	public UserMapper getUserMapper() {
		return userMapper;
	}

	public void setUserMapper(UserMapper userMapper) {
		this.userMapper = userMapper;
	}

	public User selectUser(User user) {
		return userMapper.selectUser(user);

	}

	public String selectUserAccount(String userAccount) {
		// TODO Auto-generated method stub
		return userMapper.selectUserAccount(userAccount);
	}

	public void insertUser(User user) {
		// TODO Auto-generated method stub
		userMapper.insertUser(user);

	}

	public void updateUserInfor(User user) {
		// TODO Auto-generated method stub
		userMapper.updateUserInfor(user);

	}

	public void updateUserPwd(User user) {
		// TODO Auto-generated method stub
		userMapper.updateUserPwd(user);

	}

	public User getUserInfor(int userId) {
		// TODO Auto-generated method stub
		return userMapper.getUserInfor(userId);

	}


}
